Optimal. Leaf size=262 \[ \frac {d^2 (f x)^{1+m} \left (a+c x^{2 n}\right )^p \left (1+\frac {c x^{2 n}}{a}\right )^{-p} \, _2F_1\left (\frac {1+m}{2 n},-p;1+\frac {1+m}{2 n};-\frac {c x^{2 n}}{a}\right )}{f (1+m)}+\frac {2 d e x^{1+n} (f x)^m \left (a+c x^{2 n}\right )^p \left (1+\frac {c x^{2 n}}{a}\right )^{-p} \, _2F_1\left (\frac {1+m+n}{2 n},-p;\frac {1+m+3 n}{2 n};-\frac {c x^{2 n}}{a}\right )}{1+m+n}+\frac {e^2 x^{1+2 n} (f x)^m \left (a+c x^{2 n}\right )^p \left (1+\frac {c x^{2 n}}{a}\right )^{-p} \, _2F_1\left (\frac {1+m+2 n}{2 n},-p;\frac {1+m+4 n}{2 n};-\frac {c x^{2 n}}{a}\right )}{1+m+2 n} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.10, antiderivative size = 262, normalized size of antiderivative = 1.00, number of steps
used = 10, number of rules used = 4, integrand size = 26, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.154, Rules used = {1575, 372,
371, 20} \begin {gather*} \frac {d^2 (f x)^{m+1} \left (a+c x^{2 n}\right )^p \left (\frac {c x^{2 n}}{a}+1\right )^{-p} \, _2F_1\left (\frac {m+1}{2 n},-p;\frac {m+1}{2 n}+1;-\frac {c x^{2 n}}{a}\right )}{f (m+1)}+\frac {2 d e x^{n+1} (f x)^m \left (a+c x^{2 n}\right )^p \left (\frac {c x^{2 n}}{a}+1\right )^{-p} \, _2F_1\left (\frac {m+n+1}{2 n},-p;\frac {m+3 n+1}{2 n};-\frac {c x^{2 n}}{a}\right )}{m+n+1}+\frac {e^2 x^{2 n+1} (f x)^m \left (a+c x^{2 n}\right )^p \left (\frac {c x^{2 n}}{a}+1\right )^{-p} \, _2F_1\left (\frac {m+2 n+1}{2 n},-p;\frac {m+4 n+1}{2 n};-\frac {c x^{2 n}}{a}\right )}{m+2 n+1} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 20
Rule 371
Rule 372
Rule 1575
Rubi steps
\begin {align*} \int (f x)^m \left (d+e x^n\right )^2 \left (a+c x^{2 n}\right )^p \, dx &=\int \left (d^2 (f x)^m \left (a+c x^{2 n}\right )^p+2 d e x^n (f x)^m \left (a+c x^{2 n}\right )^p+e^2 x^{2 n} (f x)^m \left (a+c x^{2 n}\right )^p\right ) \, dx\\ &=d^2 \int (f x)^m \left (a+c x^{2 n}\right )^p \, dx+(2 d e) \int x^n (f x)^m \left (a+c x^{2 n}\right )^p \, dx+e^2 \int x^{2 n} (f x)^m \left (a+c x^{2 n}\right )^p \, dx\\ &=\left (2 d e x^{-m} (f x)^m\right ) \int x^{m+n} \left (a+c x^{2 n}\right )^p \, dx+\left (e^2 x^{-m} (f x)^m\right ) \int x^{m+2 n} \left (a+c x^{2 n}\right )^p \, dx+\left (d^2 \left (a+c x^{2 n}\right )^p \left (1+\frac {c x^{2 n}}{a}\right )^{-p}\right ) \int (f x)^m \left (1+\frac {c x^{2 n}}{a}\right )^p \, dx\\ &=\frac {d^2 (f x)^{1+m} \left (a+c x^{2 n}\right )^p \left (1+\frac {c x^{2 n}}{a}\right )^{-p} \, _2F_1\left (\frac {1+m}{2 n},-p;1+\frac {1+m}{2 n};-\frac {c x^{2 n}}{a}\right )}{f (1+m)}+\left (2 d e x^{-m} (f x)^m \left (a+c x^{2 n}\right )^p \left (1+\frac {c x^{2 n}}{a}\right )^{-p}\right ) \int x^{m+n} \left (1+\frac {c x^{2 n}}{a}\right )^p \, dx+\left (e^2 x^{-m} (f x)^m \left (a+c x^{2 n}\right )^p \left (1+\frac {c x^{2 n}}{a}\right )^{-p}\right ) \int x^{m+2 n} \left (1+\frac {c x^{2 n}}{a}\right )^p \, dx\\ &=\frac {d^2 (f x)^{1+m} \left (a+c x^{2 n}\right )^p \left (1+\frac {c x^{2 n}}{a}\right )^{-p} \, _2F_1\left (\frac {1+m}{2 n},-p;1+\frac {1+m}{2 n};-\frac {c x^{2 n}}{a}\right )}{f (1+m)}+\frac {2 d e x^{1+n} (f x)^m \left (a+c x^{2 n}\right )^p \left (1+\frac {c x^{2 n}}{a}\right )^{-p} \, _2F_1\left (\frac {1+m+n}{2 n},-p;\frac {1+m+3 n}{2 n};-\frac {c x^{2 n}}{a}\right )}{1+m+n}+\frac {e^2 x^{1+2 n} (f x)^m \left (a+c x^{2 n}\right )^p \left (1+\frac {c x^{2 n}}{a}\right )^{-p} \, _2F_1\left (\frac {1+m+2 n}{2 n},-p;\frac {1+m+4 n}{2 n};-\frac {c x^{2 n}}{a}\right )}{1+m+2 n}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.21, size = 189, normalized size = 0.72 \begin {gather*} x (f x)^m \left (a+c x^{2 n}\right )^p \left (1+\frac {c x^{2 n}}{a}\right )^{-p} \left (\frac {d^2 \, _2F_1\left (\frac {1+m}{2 n},-p;1+\frac {1+m}{2 n};-\frac {c x^{2 n}}{a}\right )}{1+m}+e x^n \left (\frac {2 d \, _2F_1\left (\frac {1+m+n}{2 n},-p;\frac {1+m+3 n}{2 n};-\frac {c x^{2 n}}{a}\right )}{1+m+n}+\frac {e x^n \, _2F_1\left (\frac {1+m+2 n}{2 n},-p;\frac {1+m+4 n}{2 n};-\frac {c x^{2 n}}{a}\right )}{1+m+2 n}\right )\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [F]
time = 0.06, size = 0, normalized size = 0.00 \[\int \left (f x \right )^{m} \left (d +e \,x^{n}\right )^{2} \left (a +c \,x^{2 n}\right )^{p}\, dx\]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: TypeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int {\left (a+c\,x^{2\,n}\right )}^p\,{\left (f\,x\right )}^m\,{\left (d+e\,x^n\right )}^2 \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________